// MessageType.cs
//
// This file is part of the QuickStart Engine. See http://www.codeplex.com/QuickStartEngine
// for license details.

using System;

namespace Alex_s_Dream_The_Toy_World
{
    /// <summary>
    /// Defines the core message types
    /// </summary>
    /// <remarks>
    /// Core engine messages are in the range of 0 to 100000, please use another range for custom messages
    /// <see cref="int.MinValue"/> denotes a unknown message
    /// </remarks>
    public static class MessageType
    {
        /// <summary>
        /// Unknown message
        /// </summary>
        public const int Unknown = int.MinValue;

        #region Core Engine Messages (0 - 999)

        /// <summary>
        /// Shutdown message
        /// </summary>
        public const int Shutdown = 0;

        /// <summary>
        /// Removes an entity from all scenes
        /// </summary>
        public const int RemoveEntity = 1;

        /// <summary>
        /// Get list of all entity IDs
        /// </summary>
        public const int GetEntityIDList = 2;

        /// <summary>
        /// Adds an entity's physics actor to a physics scene
        /// </summary>
        public const int AddEntityToPhysicsScene = 3;

        /// <summary>
        /// Removes an entity's physics actor from a physics scene
        /// </summary>
        public const int RemoveEntityFromPhysicsScene = 4;

        /// <summary>
        /// Returns a reference to the physics scene
        /// </summary>
        public const int GetPhysicsScene = 5;

        /// <summary>
        /// Begins a physics frame
        /// </summary>
        public const int BeginPhysicsFrame = 6;

        /// <summary>
        /// Ends a physics frame
        /// </summary>
        public const int EndPhysicsFrame = 7;

        /// <summary>
        /// Set gravity
        /// </summary>
        public const int SetGravity = 8;

        /// <summary>
        /// Get gravity
        /// </summary>
        public const int GetGravity = 9;

        /// <summary>
        /// Sets the physics fixed time step frequency.
        /// </summary>
        public const int SetPhysicsTimeStep = 10;


        /// <summary>
        /// Tells the engine which entity is currently the controlled entity.
        /// </summary>
        public const int SetControlledEntity = 20;

        /// <summary>
        /// Gets the current controlled entity.
        /// </summary>
        public const int GetControlledEntity = 21;

        /// <summary>
        /// Lets an entity know it is being controlled (or no longer being controlled)
        /// </summary>
        public const int SetIsControlled = 22;

        /// <summary>
        /// Gets an entity based on its Unique ID.
        /// </summary>
        public const int GetEntityByID = 23;

        /// <summary>
        /// Gets the name of an entity.
        /// </summary>
        public const int GetName = 24;

        /// <summary>
        /// Gets the active scene's fog settings.
        /// </summary>
        public const int GetFogSettings = 25;

        #endregion

        #region Keyboard Messages (1000-1999)
        /// <summary>
        /// KeyDown message
        /// </summary>
        public const int KeyDown = 1000;
        /// <summary>
        /// KeyPress message
        /// </summary>
        public const int KeyHeld = 1001;
        /// <summary>
        /// KeyUp message
        /// </summary>
        public const int KeyUp = 1002;
        #endregion

        #region Mouse Messages (2000-2999)
        /// <summary>
        /// MouseButtonDown message
        /// </summary>
        public const int MouseDown = 2000;
        /// <summary>
        /// MouseButtonPress message
        /// </summary>
        public const int MouseHeld = 2001;
        /// <summary>
        /// MouseButtonUp message
        /// </summary>
        public const int MouseUp = 2002;
        /// <summary>
        /// MouseScroll message
        /// </summary>
        public const int MouseScroll = 2003;
        /// <summary>
        /// MouseMove message
        /// </summary>
        public const int MouseMove = 2004;
        #endregion

        #region GamePad Messages (3000-3999)
        /// <summary>
        /// GamePad ButtonUp message
        /// </summary>
        public const int ButtonUp = 3000;

        /// <summary>
        /// GamePad ButtonDown message
        /// </summary>
        public const int ButtonDown = 3001;

        /// <summary>
        /// GamePad ButtonHeld message
        /// </summary>
        public const int ButtonHeld = 3002;

        /// <summary>
        /// GamePad Trigger message
        /// </summary>
        public const int Trigger = 3003;

        /// <summary>
        /// GamePad Trigger release message. Sends a message saying the trigger has been re-centered.
        /// </summary>
        public const int TriggerRelease = 3004;

        /// <summary>
        /// GamePad Thumbstick message
        /// </summary>
        public const int Thumbstick = 3005;

        /// <summary>
        /// GamePad Thumbstick release message. Sends a message saying the thumbstick has been re-centered.
        /// </summary>
        public const int ThumbstickRelease = 3006;
        #endregion

        #region Core Camera Messages (4000-4999)
        /// <summary>
        /// Sets the current render camera
        /// </summary>
        public const int CameraSetRender = 4000;
        /// <summary>
        /// Gets the current render camera's ID
        /// </summary>
        public const int CameraGetRenderEntityID = 4001;
        /// <summary>
        /// CameraZoomIn message
        /// </summary>
        public const int CameraZoomIn = 4002;
        /// <summary>
        /// CameraZoomOut message
        /// </summary>
        public const int CameraZoomOut = 4003;
        /// <summary>
        /// CameraZoomReset message
        /// </summary>
        public const int CameraZoomReset = 4004;            // @todo: Implement
        /// <summary>
        /// CameraSetProjection message
        /// </summary>
        public const int CameraSetProjection = 4005;
        /// <summary>
        /// CameraSetView message
        /// </summary>
        public const int CameraSetViewMatrix = 4006;
        /// <summary>
        /// Get this entity's View Matrix
        /// </summary>
        public const int CameraGetViewMatrix = 4007;
        /// <summary>
        /// Get this entity's Projection Matrix
        /// </summary>
        public const int CameraGetProjectionMatrix = 4008;

        public const int GetCameraValues = 4009;
        #endregion

        #region Entity Messages (5000-5999)
        /// <summary>
        /// Set an entity to look at a specific position.
        /// </summary>
        public const int LookAtPosition = 5000;

        /// <summary>
        /// Set an entity to look at it's parent entity, if it has one.
        /// </summary>
        public const int LookAtParent = 5001;

        /// <summary>
        /// Set an entity's position
        /// </summary>
        public const int SetPosition = 5002;

        /// <summary>
        /// Get an entity's position
        /// </summary>
        public const int GetPosition = 5003;
        
        /// <summary>
        /// Modify an entity's position from its current position
        /// </summary>
        public const int ModifyPosition = 5004;

        /// <summary>
        /// Set an entity's rotation
        /// </summary>
        public const int SetRotation = 5005;

        /// <summary>
        /// Get an entity's rotation
        /// </summary>
        public const int GetRotation = 5006;

        /// <summary>
        /// Alter an entity's rotaiton from its current rotation
        /// </summary>
        public const int ModifyRotation = 5007;

        /// <summary>
        /// Get an entity's forward vector
        /// </summary>
        public const int GetVectorForward = 5008;

        /// <summary>
        /// Get an entity's up vector
        /// </summary>
        public const int GetVectorUp = 5009;

        /// <summary>
        /// Get an entity's right vector
        /// </summary>
        public const int GetVectorRight = 5010;

        #region Physics Messages
        /// <summary>
        /// Sets an entity's linear velocity
        /// </summary>
        public const int SetLinearVelocity = 5011;

        /// <summary>
        /// Gets an entity's linear velocity
        /// </summary>
        public const int GetLinearVelocity = 5012;

        /// <summary>
        /// Sets an entity's angular velocity
        /// </summary>
        public const int SetAngularVelocity = 5013;

        /// <summary>
        /// Gets an entity's angular velocity (rate of spin)
        /// </summary>
        public const int GetAngularVelocity = 5014;

        /// <summary>
        /// Adds a linear force to an entity
        /// </summary>
        public const int AddLinearForce = 5015;

        /// <summary>
        /// Adds an angular force to an entity
        /// </summary>
        public const int AddAngularForce = 5016;

        /// <summary>
        /// Sent when a collision occurs with a physics object registered for collision listening
        /// </summary>
        public const int Collision = 5017;

        /// <summary>
        /// Sent when a collision is no longer occuring
        /// </summary>
        public const int CollisionOff = 5018;

        /// <summary>
        /// Tells an object to listen or stop listen for collisions.
        /// </summary>
        public const int ListenForCollision = 5019;

        /// <summary>
        /// Add a collision effect to the entity.
        /// </summary>
        public const int AddCollisionEffect = 5020;

        /// <summary>
        /// Remove a collision effect from an entity.
        /// </summary>
        public const int RemoveCollisionEffect = 5021;

        /// <summary>
        /// Initialize a collision effect. Do this after the effect has been added.
        /// </summary>
        public const int InitCollisionEffect = 5022;

        /// <summary>
        /// Get whether or not an entity's physics are dynamic (movable) or not.
        /// </summary>
        public const int GetHasDynamicPhysics = 5023;

        /// <summary>
        /// Set an entity's physics to be movable (dynamic) or non-movable.
        /// </summary>
        public const int SetPhysicsMovableState = 5024;
        #endregion

        #region Character Controller Messages
        /// <summary>
        /// Base a character's movement on the camera rotation
        /// </summary>
        public const int LockCharRotationToCamera = 5100;

        /// <summary>
        /// Gets whether or not this entity is a character.
        /// </summary>
        public const int GetIsACharacter = 5101;
        #endregion


        /// <summary>
        /// Yaw an entity.
        /// </summary>
        public const int Yaw = 5200;

        /// <summary>
        /// Yaw an entity using the world Up axis.
        /// </summary>
        public const int YawWorldUp = 5201;

        /// <summary>
        /// Pitch an entity.
        /// </summary>
        public const int Pitch = 5202;

        /// <summary>
        /// Roll an entity.
        /// </summary>
        public const int Roll = 5203;

        /// <summary>
        /// Strafe an entity.
        /// </summary>
        public const int Strafe = 5204;

        /// <summary>
        /// Walk an entity.
        /// </summary>
        public const int Walk = 5205;

        /// <summary>
        /// Jump an entity.
        /// </summary>
        public const int Jump = 5206;

        /// <summary>
        /// Get the height of the terrain at any X,Z coordinates
        /// </summary>
        public const int GetTerrainHeightAtXZ = 5207;

        /// <summary>
        /// Get the entire terrain entity for use.
        /// </summary>
        public const int GetTerrainEntity = 5208;

        /// <summary>
        /// Gets terrain properties
        /// </summary>
        public const int GetTerrainProperties = 5209;

        /// <summary>
        /// Tells terrain to display bounding boxes.
        /// </summary>
        public const int ToggleTerrainDisplayBoundingBoxes = 5210;

        /// <summary>
        /// Call this to generate a nav mesh
        /// </summary>
        public const int GenerateNavMesh = 5211;

        /// <summary>
        /// Send this message to an Entity that has a sky component to attach the sky to the camera.
        /// </summary>
        public const int SkyAttachToCamera = 5212;

        /// <summary>
        /// Sets an entity into a constant rotation
        /// </summary>
        public const int SetConstantRotation = 5213;

        /// <summary>
        /// Sets an entity into a constant sine wave movement
        /// </summary>
        public const int SetConstantMovement = 5214;

        /// <summary>
        /// Sets a cube map texture for the graphics system to use.
        /// </summary>
        public const int SetCubeMapTexture = 5215;

        /// <summary>
        /// Lets the graphics system know about the water's elevation, even if the water
        /// plane is not in the view frustum this frame, that way other systems, like terrain
        /// can know about the water.
        /// </summary>
        public const int SetRenderWaterElevation = 5216;

        #region Render Messages
        /// <summary>
        /// Gets all of the vertices that make up a model
        /// </summary>
        public const int GetModelVertices = 5300;

        /// <summary>
        /// Gets all of the indices that make up a model
        /// </summary>
        public const int GetModelIndices = 5301;

        /// <summary>
        /// Gets the file path for the model on an entity
        /// </summary>
        public const int GetModelPath = 5302;

        /// <summary>
        /// Gets a list of vertices and indices for a standard XNA model
        /// </summary>
        public const int GetVerticesIndicesInfoFromModel = 5303;

        /// <summary>
        /// Sets the color of a model
        /// </summary>
        public const int SetModelColor = 5304;

        /// <summary>
        /// Gets the color of a model
        /// </summary>
        public const int GetModelColor = 5305;

        /// <summary>
        /// Sets the opacity of a model
        /// </summary>
        public const int SetModelOpacity = 5306;

        /// <summary>
        /// Gets the opacity of a model
        /// </summary>
        public const int GetModelOpacity = 5307;
        #endregion


        /// <summary>
        /// Gets movement info from a character's input component.
        /// </summary>
        public const int GetCharacterMovementInfo = 5400;


        /// <summary>
        /// Adds an entity as a child of another entity
        /// </summary>
        public const int SetParent = 5500;

        /// <summary>
        /// Removes a child entity from an entity
        /// </summary>
        public const int RemoveChild = 5501;

        /// <summary>
        /// Lets a child entity know the parent was removed from it
        /// </summary>
        public const int ParentRemoved = 5502;

        /// <summary>
        /// Lets a child entity know it was given a parent
        /// </summary>
        public const int ParentAdded = 5503;

        /// <summary>
        /// Lets a parent entity know a child was removed from it
        /// </summary>
        public const int ChildRemoved = 5504;

        /// <summary>
        /// Lets a parent entity know a child was added to it
        /// </summary>
        public const int ChildAdded = 5505;

        /// <summary>
        /// Gets the ID of an entity's parent
        /// </summary>
        public const int GetParentID = 5506;

        #region Water Messages
        /// <summary>
        /// Sets the color of a water plane
        /// </summary>
        public const int SetWaterColor = 5600;
        /// <summary>
        /// Sets the reflectivity of water, 0.0f being no reflection at all, 1.0f being 100% reflection (no refraction)
        /// </summary>
        public const int SetWaterReflectivity = 5601;
        #endregion

        #endregion       

        #region AI Messages (6000-6999)
        /// <summary>
        /// AI Movement Message
        /// </summary>
        public const int GetAIMovementInfo = 6000;
        #endregion
    }
}
